home *** CD-ROM | disk | FTP | other *** search
/ Meeting Pearls 1 / Meeting Pearls Vol 1 (1994).iso / installed_progs / text / faqs / graphics.gnuplot-faq < prev    next >
Encoding:
Internet Message Format  |  1994-05-11  |  39.3 KB

  1. Subject: comp.graphics.gnuplot FAQ (Frequent Answered Questions)
  2. Newsgroups: comp.graphics.gnuplot,comp.answers,news.answers
  3. From: ig25@fg70.rz.uni-karlsruhe.de (Thomas Koenig)
  4. Date: 10 May 1994 02:23:30 GMT
  5.  
  6.  
  7. Archive-name: graphics/gnuplot-faq
  8. Version: Fri May  6 04:23:05 MESZ 1994
  9. Posting-frequency: every 14 days
  10. X-Url: http://fg20.rz.uni-karlsruhe.de/~ig25/gnuplot-faq
  11.  
  12.    comp.graphics.gnuplot
  13.    
  14.             COMP.GRAPHICS.GNUPLOT FAQ (FREQUENT ANSWERED QUESTIONS)
  15.                                        
  16.    This is the FAQ (Frequently Answered Questions) list of the
  17.    comp.graphics.gnuplot newsgroup, which discusses the gnuplot program
  18.    for plotting 2D - and 3D - graphs.
  19.    
  20.    Most of the information in this document came from public discussion
  21.    on comp.graphics.gnuplot; quotations are believed to be in the public
  22.    domain.
  23.    
  24.    Here's a list of the questions. If you are looking for the answer for
  25.    a specific question, look for the string Qx.x: at the beginning of a
  26.    line, with x.x being the question number. Sections in this FAQ are
  27.      * 0. Meta - Questions
  28.      * 1. General Information
  29.      * 2. Setting it up
  30.      * 3. Working with it
  31.      * 4. Wanted features
  32.      * 5. Miscellaneous
  33.      * 6. Making life easier
  34.      * 7. Known problems
  35.      * 8. Credits
  36.        
  37.    
  38.      _________________________________________________________________
  39.    
  40. Questions:
  41.  
  42.   SECTION 0: META - QUESTIONS
  43.      * Q0.1: Where do I get this document?
  44.      * Q0.2: Where do I send comments about this document?
  45.        
  46.   SECTION 1: GENERAL INFORMATION
  47.      * Q1.1: What is gnuplot?
  48.      * Q1.2: How did it come about and why is it called gnuplot?
  49.      * Q1.3: Does gnuplot have anything to do with the FSF and the GNU
  50.        project?
  51.      * Q1.4: What does gnuplot offer?
  52.      * Q1.5: Is gnuplot suitable for batch processing?
  53.      * Q1.6: Can I run gnuplot on my computer?
  54.        
  55.   SECTION 2: SETTING IT UP
  56.      * Q2.1: What is the current version of gnuplot?
  57.      * Q2.2: Where can I get gnuplot?
  58.      * Q2.3: How do I get gnuplot to compile on my system?
  59.      * Q2.4: What documentation is there, and how do I get it?
  60.        
  61.   SECTION 3: WORKING WITH IT
  62.      * Q3.1: How do I get help?
  63.      * Q3.2: How do I print out my graphs?
  64.      * Q3.3: How do I include my graphs in <word processor>?
  65.        
  66.   SECTION 4: WANTED FEATURES
  67.      * Q4.1: Does gnuplot have hidden line removal?
  68.      * Q4.2: Does gnuplot support bar-charts/histograms/boxes?
  69.      * Q4.3: Does gnuplot support multiple y-axes on a single plot?
  70.      * Q4.4: Can I put multiple plots on a single page?
  71.      * Q4.5: Can I put both data files and commands into a single file?
  72.      * Q4.6: Can I put Greek letters and super/subscripts into my labels?
  73.      * Q4.7 Can I do 1:1 scaling of axes?
  74.      * Q4.8: Can I put tic marks for x and y axes into 3d plots?
  75.      * Q4.9: Does gnuplot support a driver for ?
  76.      * Q4.10: Can I put different text sizes into my plots?
  77.        
  78.   SECTION 5: MISCELLANEOUS
  79.      * Q5.1: I've found a bug, what do I do?
  80.      * Q5.2: Can I use gnuplot routines for my own programs?
  81.      * Q5.3: What extensions have people made to gnuplot? Where can I get
  82.        them?
  83.      * Q5.4: Can I do heavy - duty data processing with gnuplot?
  84.      * Q5.5: I have ported gnuplot to another system, or patched it. What
  85.        do I do?
  86.        
  87.   SECTION 6: MAKING LIFE EASIER
  88.      * Q6.1: How do I plot two functions in non - overlapping regions?
  89.      * Q6.2: How do I run my data through a filter before plotting?
  90.      * Q6.3: How do I make it easier to use gnuplot with LaTeX?
  91.      * Q6.4: How do I save and restore my settings?
  92.      * Q6.5: How do I plot lines (not grids) using splot?
  93.      * Q6.6: How do I plot a function f(x,y) which is bounded by other
  94.        functions in the x-y plain?
  95.      * Q6.7: How do I get rid of <feature in a plot>?
  96.      * Q6.8: How do I call gnuplot from my own programs ?
  97.        
  98.   SECTION 7: KNOWN PROBLEMS
  99.      * Q7.1: Gnuplot is not plotting any points under X11! How come?
  100.      * Q7.2: My isoline data generated by a Fortran program is not
  101.        handled correctly. What can I do?
  102.      * Q7.3: Why does gnuplot ignore my very small numbers?
  103.      * Q7.4: Gnuplot is plotting nothing when run via gnuplot <filename>!
  104.        What can I do?
  105.      * Q7.5: My formulas are giving me nonsense results! What's going on?
  106.        
  107.   SECTION 8: CREDITS
  108.   
  109.   SECTION 0: META - QUESTIONS.
  110.   
  111.     Q0.1: Where do I get this document?
  112.           This document is posted about once every two weeks to the
  113.           newsgroups comp.graphics.gnuplot, comp.answers and
  114.           news.answers. Like many other FAQ's, its newest (plaintext)
  115.           version is available via anonymous ftp from
  116.           ftp://rtfm.mit.edu/pub/usenet/news.answers/graphics/gnuplot-faq
  117.           .
  118.           
  119.           If you have access to the WWW, you can get the newest version
  120.           of this document from
  121.           http://fg20.rz.uni-karlsruhe.de/~ig25/gnuplot-faq.html
  122.           
  123.    Q0.2: Where do I send comments about this document?
  124.           Send comments, suggestions etc. via e-mail to Thomas Koenig ,
  125.           ig25@rz.uni-karlsruhe.de or ig25@dkauni2.bitnet.
  126.           
  127.    
  128.      _________________________________________________________________
  129.    
  130.   SECTION 1: GENERAL INFORMATION
  131.   
  132.     Q1.1: What is gnuplot?
  133.           Gnuplot is a command-driven interactive function plotting
  134.           program. It can be used to plot functions and data points in
  135.           both two- and three- dimensional plots in many different
  136.           formats, and will accommodate many of the needs of today's
  137.           scientists for graphic data representation. Gnuplot is
  138.           copyrighted, but freely distributable; you don't have to pay
  139.           for it.
  140.           
  141.    Q1.2: How did it come about and why is it called gnuplot?
  142.           The authors of gnuplot are:
  143.           
  144.           Thomas Williams, Colin Kelley, Russell Lang, Dave Kotz, John
  145.           Campbell, Gershon Elber, Alexander Woo and many others.
  146.           
  147.           The following quote comes from Thomas Williams:
  148.           
  149.      I was taking a differential equation class and Colin was taking
  150.      Electromagnetics, we both thought it'd be helpful to visualize the
  151.      mathematics behind them. We were both working as sys admin for an EE
  152.      VLSI lab, so we had the graphics terminals and the time to do some
  153.      coding. The posting was better received than we expected, and
  154.      prompted us to add some, albeit lame, support for file data.
  155.      
  156.      Any reference to GNUplot is incorrect. The real name of the program
  157.      is "gnuplot". You see people use "Gnuplot" quite a bit because many
  158.      of us have an aversion to starting a sentence with a lower case
  159.      letter, even in the case of proper nouns and titles. Gnuplot is not
  160.      related to the GNU project or the FSF in any but the most peripheral
  161.      sense. Our software was designed completely independently and the
  162.      name "gnuplot" was actually a compromise. I wanted to call it
  163.      "llamaplot" and Colin wanted to call it "nplot." We agreed that
  164.      "newplot" was acceptable but, we then discovered that there was an
  165.      absolutely ghastly pascal program of that name that the Computer
  166.      Science Dept. occasionally used. I decided that "gnuplot" would make
  167.      a nice pun and after a fashion Colin agreed.
  168.      
  169.    Q1.3: Does gnuplot have anything to do with the FSF and the GNU
  170.           project?
  171.           Gnuplot is neither written nor maintained by the FSF. It is not
  172.           covered by the General Public License, either.
  173.           
  174.           However, the FSF has decided to distribute gnuplot as part of
  175.           the GNU system, because it is useful, redistributable software.
  176.           
  177.    Q1.4: What does gnuplot offer?
  178.           
  179.           + Plotting of two - dimensional functions and data points in
  180.             many different styles (points, lines, error bars)
  181.           + plotting of three - dimensional data points and surfaces in
  182.             many different styles (contour plot, mesh).
  183.           + support for complex arithmetic
  184.           + self - defined functions
  185.           + support for a large number of operating systems, graphics
  186.             file formats and devices
  187.           + extensive on-line help
  188.           + labels for title, axes, data points
  189.           + command line editing and history on most platforms
  190.             
  191.    Q1.5: Is gnuplot suitable for batch processing?
  192.           Yes. You can read in files from the command line, or you can
  193.           redirect your standard input to read from a file. Both data and
  194.           command files can be generated automatically, from data
  195.           acquisition programs or whatever else you use.
  196.           
  197.    Q1.6: Can I run gnuplot on my computer?
  198.           Gnuplot is available for a number of platforms. These are: Unix
  199.           (X11 and NeXTSTEP), VAX/VMS, OS/2, MS-DOS, Amiga, MS-Windows,
  200.           OS-9/68k, Atari ST and the Macintosh. Modifications for NEC
  201.           PC-9801 are said to exist (where?).
  202.           
  203.    
  204.      _________________________________________________________________
  205.    
  206.   SECTION 2: SETTING IT UP
  207.   
  208.     Q2.1: What is the current version of gnuplot?
  209.           The current version of gnuplot is 3.5, which is a bugfix
  210.           release over 3.4.
  211.           
  212.    Q2.2: Where can I get gnuplot?
  213.           [This information may be dated, due to the release of gnuplot
  214.           3.5. Please report any inaccuracies, if you find them. Ed.]
  215.           
  216.           All of the later addresses refer to ftp sites. Please note that
  217.           it is preferable for you to use the symbolic name, rather than
  218.           the IP address given in brackets, because that address is much
  219.           more subject to change.
  220.           
  221.           The official distribution site for the gnuplot source is
  222.           ftp.dartmouth.edu [129.170.16.4], the file is called
  223.           /pub/gnuplot/gnuplot3.5.tar.Z. Official mirrors of that
  224.           distribution are (for Australia) monu1.cc.monash.edu.au
  225.           [130.194.1.101] and (for Europe) irisa.irisa.fr
  226.           [131.254.254.2]. You can also get it from your friendly
  227.           neighbourhood comp.sources.misc archive.
  228.           
  229.           MS-DOS and MS-Windows binaries are available from
  230.           
  231.           + oak.oakland.edu (North America) [141.210.10.117] as
  232.             pub/msdos/plot/gpt35*.zip,
  233.           + garbo.uwasa.fi (Europe) [128.214.87.1] as /pc/plot/gpt35*.zip
  234.             and
  235.           + archie.au (Australia) [139.130.4.6] as
  236.             micros/pc/oak/plot/gpt35*.zip.
  237.             
  238.    The files are: gpt35doc.zip, gpt35exe.zip, gpt35src.zip and
  239.           gpt35win.zip.
  240.           
  241.           There is a special MS-DOS version for 386 or better processors;
  242.           it is available from the official gnuplot sites as DOS34.zip.
  243.           
  244.           OS/2 2.x binaries are at ftp-os2.nmsu.edu [128.123.35.151], in
  245.           /os2/2.x/unix/gnuplt35.zip.
  246.           
  247.           Amiga sources and binaries are available from ftp.wustl.edu
  248.           [128.252.135.4] as /pub/aminet/util/gnu/gnuplot-3.5.lha; there
  249.           are numerous mirrors of this distribution, for example
  250.           ftp.uni-kl.de, oes.orst.edu or ftp.luth.se.
  251.           
  252.           The NeXTSTEP front end can be found at sonata.cc.purdue.edu and
  253.           cs.orst.edu.
  254.           
  255.           A version for OS-9/68K can be found at cabrales.cs.wisc.edu
  256.           [128.105.36.20] as /pub/OSK/GRAPHICS/gnuplot32x.tar.Z; it
  257.           includes both X-Windows and non - X-windows versions.
  258.           
  259.           A version of gnuplot for the Mac can reportedly be found on
  260.           archive.umich.edu and sumex-aim.stanford.edu, directories
  261.           unknown.
  262.           
  263.           Executable files, plus documentation in Japanese, exist for the
  264.           X680x0 on ftp.csis.oita-u.ac.jp [133.37.56.112] in
  265.           /pub/x68k/fj.binaries.x68000/vol2/gnuplt35.lzh.
  266.           
  267.           People without ftp access can use an ftp-mail server; send a
  268.           message saying 'help' to bitftp@pucc.bitnet (for BITNET only)
  269.           or to ftpmail@ftp.dartmouth.edu.
  270.           
  271.           For a uuencoded copy of the the gnuplot sources (compressed tar
  272.           file), send this as the body of a message to
  273.           ftpmail@ftp.dartmouth.edu:
  274.           
  275.  
  276.         open
  277.         cd pub/gnuplot
  278.         mode binary
  279.         get gnuplot3.5.tar.Z
  280.         quit
  281.  
  282.    If you have some problem, you might need to stick
  283.           
  284.  
  285.         reply-to  <your-email-address-here>
  286.  
  287.    before all the above.
  288.           
  289.           It is a good idea to look for a nearby ftp site when
  290.           downloading things. You can use archie for this. See if an
  291.           archie client is installed at your system (by simply typing
  292.           archie at the command prompt), or send mail to archie@sura.net
  293.           with the word 'help' in both the subject line and the body of
  294.           the mail. However, be aware that the version you find at a near
  295.           ftp site may well be out of date; check the last modification
  296.           date and the number of bytes against the newest release at one
  297.           of the official servers.
  298.           
  299.    Q2.3: How do I get gnuplot to compile on my system?
  300.           As you would any other installation. Read the files README and
  301.           README.Install, edit the Makefile according to taste, and run
  302.           make or whatever is suitable for your operating system.
  303.           
  304.           If you get a complaint about a missing file libplot.a or
  305.           something similar when building gnuplot for X11, remove
  306.           -DUNIXPLOT from the TERMFLAGS= line, remove -lplot from the
  307.           DTBS= line and run again. If you are making X11 on a sun, type
  308.           'make x11_sun'.
  309.           
  310.    Q2.4: What documentation is there, and how do I get it?
  311.           The documentation is included in the source distribution. Look
  312.           at the docs subdirectory, where you'll find
  313.           
  314.           + a Unix man page, which says how to start gnuplot
  315.           + a help file, which also can be printed as a manual
  316.           + a tutorial on using gnuplot with LaTeX
  317.           + a quick reference summary sheet for TeX only
  318.             
  319.    PostScript copies of the documentation can be ftp'd from
  320.           ftp.dartmouth.edu, in pub/gnuplot, as manual.ps.Z and
  321.           tutorial.ps.Z
  322.           
  323.           A Chinese translation of the manual can be found on
  324.           ftp://servers.nctu.edu.tw/misc/environment/NCTU_EV/classnote/gn
  325.           uplot.ps.gz .
  326.           
  327.    
  328.      _________________________________________________________________
  329.    
  330.   SECTION 3: WORKING WITH IT
  331.   
  332.     Q3.1: How do I get help?
  333.           Give the 'help' command at the initial prompt. After that, keep
  334.           looking through the keywords. Good starting points are 'plot'
  335.           and 'set'.
  336.           
  337.           Read the manual, if you have it.
  338.           
  339.           Look through the demo subdirectory; it should give you some
  340.           ideas.
  341.           
  342.           Ask your colleagues, the system administrator or the person who
  343.           set up gnuplot.
  344.           
  345.           Post a question to comp.graphics.gnuplot or send mail to the
  346.           gatewayed mailing list info-gnuplot@dartmouth.edu. If you want
  347.           to subscribe to the mailing list, send mail to
  348.           info-gnuplot-request@dartmouth.edu, but please don't do this if
  349.           you can get comp.graphics.gnuplot directly. If you pose a
  350.           question there, it is considered good form to solicit e-mail
  351.           replies and post a summary.
  352.           
  353.    Q3.2: How do I print out my graphs?
  354.           The kind of output produced is determined by the 'set terminal'
  355.           command; for example, 'set terminal postscript' will produce
  356.           the graph in PostScript format. Output can be redirected using
  357.           the 'set output' command.
  358.           
  359.           As an example, the following prints out a graph of sin(x) on a
  360.           Unix machine running X - Windows.
  361.           
  362.  
  363.         gnuplot> plot [-6:6] sin(x)
  364.         gnuplot> set terminal postscript
  365.         Terminal type set to 'postscript'
  366.         Options are 'landscape monochrome "Courier" 14'
  367.         gnuplot> set output "sin.ps"
  368.         gnuplot> replot
  369.         gnuplot> set output              # set output back to default
  370.         gnuplot> set terminal x11        # ditto for terminal type
  371.         gnuplot> ! lp -ops sin.ps        # print ps - File (site dependent)
  372.         request id is lprint-3433 (standard input)
  373.         lp: printed file sin.ps on fg20.rz.uni-karlsruhe.de (5068 Byte)
  374.         !
  375.         gnuplot>
  376.  
  377.    Q3.3: How do I include my graphs in <word processor>?
  378.           Basically, you save your plot to a file in a format your word
  379.           processor can understand (using "set term" and "set output",
  380.           see above), and then you read in the plot from your word
  381.           processor.
  382.           
  383.           Details depend on the kind of word processor you use; use "set
  384.           term" to get a list of available file formats.
  385.           
  386.           Many word processors can use Encapsulated PostScript for
  387.           graphs. This can be generated by the "set terminal postscript
  388.           eps" command. Most MS-DOS word processors understand HPGL
  389.           (terminal type hpgl).
  390.           
  391.           With TeX, it depends on what you use to print your dvi files.
  392.           If you use dvips or dvi2ps, you can use Encapsulated
  393.           PostScript. For emTeX (popular for MS-DOS), you can use emTeX,
  394.           otherwise use the LaTeX terminal type, which generates a
  395.           picture environment.
  396.           
  397.           If nothing else helps, try using the pgm or ppm format and
  398.           converting it to a bitmap format your favourite word processor
  399.           can understand. An invaluable tool for this is Jef Poskanzer's
  400.           PBMPLUS package.
  401.           
  402.           The PBMPLUS package is available in the contrib distribution
  403.           for Xwindows. The original site for this is ftp.x.org:/contrib,
  404.           there are many mirrors, e.g.
  405.           ftp.th-darmstadt.de:/pub/X11/contrib or
  406.           sunsite.unc.edu:/pub/X11/contrib.
  407.           
  408.           The most recent release of pbm by the author is dated December
  409.           91 and is called pbmplus10dec91.tar.Z
  410.           
  411.           There is new version including lots of patches from the net
  412.           that is not maintained by the author called netpbm, with the
  413.           newest version called netpbm-7dec1993.tar.gz.
  414.           
  415.           Check archie (see Q2.2 ) for an archive site near you.
  416.           
  417.    
  418.      _________________________________________________________________
  419.    
  420.   SECTION 4: WANTED FEATURES
  421.   
  422.     Q4.1: Does gnuplot have hidden line removal?
  423.           Version 3.5 supports hidden line removal on all platforms
  424.           except MS-DOS; use the command
  425.           
  426.  
  427.         set hidden3d
  428.  
  429.    If someone can solve the 64K DGROUP memory problem, gnuplot would
  430.           support hidden line removal on MS-DOS as well. Version 3.2
  431.           supports limited hidden line removal.
  432.           
  433.    Q4.2: Does gnuplot support bar-charts/histograms/boxes?
  434.           As of version 3.4, it does.
  435.           
  436.    Q4.3: Does gnuplot support multiple y-axes on a single plot?
  437.           Yes, with two unofficial mods, multiplot.shar and borders.shar.
  438.           Send mail to woo@playfair.stanford.edu.
  439.           
  440.    Q4.4: Can I put multiple plots on a single page?
  441.           Yes, with the multiplot.shar mod. If you are using PostScript
  442.           output, check out mpage, which can be ftp'd from
  443.           ftp.eng.umd.edu:pub/misc/mpage-2.tar.Z
  444.           
  445.    Q4.5: Can I put both data files and commands into a single file?
  446.           This is a feature which will probably be in gnuplot 3.6, which
  447.           is in early development. Ask for the mixed.shar patch from
  448.           woo@playfair.stanford.edu.
  449.           
  450.    Q4.6: Can I put Greek letters and super/subscripts into my labels?
  451.           You might try using the LaTeX terminal type and putting text
  452.           like \alpha_{3} into it.
  453.           
  454.           If you use PostScript output, you might find something in the
  455.           Green subdirectory of the gpcontrb file (see Q5.3).
  456.           
  457.           David Denholm has written a PostScript terminal which allows
  458.           for super/and subscripts, such as a^x or { Symbol a }. Ftp to
  459.           sotona.phys.soton.ac.uk[152.78.192.42] and get divpost34.trm.
  460.           To install it, copy it over ~gnuplot/term/post.trm and
  461.           recompile. A never version is mattpost.trm, rewritten by Matt
  462.           Heffron.
  463.           
  464.    Q4.7: Can I do 1:1 scaling of axes?
  465.           Not easily.
  466.           
  467.    Q4.8: Can I put tic marks for x and y axes into 3d plots?
  468.           In version 3.5, you can.
  469.           
  470.    Q4.9: Does gnuplot support a driver for ?
  471.           To see a list of the available graphic drivers for your
  472.           installation of gnuplot, type "set term".
  473.           
  474.           Some graphics drivers are included in the normal distribution,
  475.           but are uncommented by default. If you want to use them, you'll
  476.           have to change ~gnuplot/term.h.
  477.           
  478.    Q4.10: Can I put different text sizes into my plots?
  479.           If you use PostScript output, you can use Dave Denholm's and
  480.           Matt Heffron's updated PostScript driver,
  481.           /sotona.phys.soton.ac.uk:/mattpost.trm (see also Q4.6 ).
  482.           
  483.    
  484.      _________________________________________________________________
  485.    
  486.   SECTION 5: MISCELLANEOUS
  487.   
  488.     Q5.1: I've found a bug, what do I do?
  489.           First, try to see whether it actually is a bug, or whether it
  490.           is a feature which may be turned off by some obscure set -
  491.           command.
  492.           
  493.           Next, see wether you have an old version of gnuplot; if you do,
  494.           chances are the bug has been fixed in a newer release.
  495.           
  496.           If, after checking these things, you still are convinced that
  497.           there is a bug, proceed as follows. If you have a fairly
  498.           general sort of bug report, posting to comp.graphics.gnuplot is
  499.           probably the way to go. If you have investigated a problem in
  500.           detail, especially if you have a context diff that fixes the
  501.           problem, please e-email a report to bug-gnuplot@dartmouth.edu.
  502.           The bug-gnuplot list is for reporting and collecting bug fixes,
  503.           the comp.graphics.gnuplot newsgroup will be more help for
  504.           finding work arounds or actually solving gnuplot related
  505.           problems. If you do send in a bug report, be sure and include
  506.           the version of gnuplot (including patchlevel), terminal driver,
  507.           operating system, an exact description of the bug and input
  508.           which can reproduce the bug. Also, any context diffs should be
  509.           referenced against the latest official version of gnuplot if at
  510.           all possible.
  511.           
  512.    Q5.2: Can I use gnuplot routines for my own programs?
  513.           Yes. John Campbell has written gplotlib, a version of gnuplot
  514.           as C subroutines callable from a C program. This is available
  515.           as gplotlib.tar.Z on the machine ftp.nau.edu in the directory
  516.           /pub/gplotlib.tar.Z. This library has been updated to be
  517.           compatible with version 3.5. Ask woo@playfair.stanford.edu.
  518.           
  519.    Q5.3: What extensions have people made to gnuplot? Where can I get
  520.           them?
  521.           [A new gpcontrb has been put up. Unfortunately, I haven't had
  522.           a chance to check it out yet, so this information is out of
  523.           date. Expect something in the next couple of days. TK] 
  524.           
  525.           Extensions have been put into the file gpcontrb.zip, which is
  526.           available with the 3.5 release, from ftp.dartmouth.edu.
  527.           
  528.           Note that it has a size of 4.3 megabytes.
  529.           
  530.           The old version contained the following directories:
  531.           
  532.           bigler subdirectory:
  533.           From: bigler@cicg-calcul.grenet.fr
  534.           Subject: Multiple plots from a Fortran program
  535.           budelsky subdirectory:
  536.           From: budelsky@haegar.ikp.uni-koeln.de
  537.           Subject: This is the information file for porting gnuplot 3.2
  538.           to OS-9/68000
  539.           byrne subdirectory:
  540.           From: "Margaret R. Byrne"
  541.           Subject: congp3d3 preprocessor to draw contour plots on
  542.           irregular regions.
  543.           clark subdirectory:
  544.           From: Michael Clark
  545.           Subject: data filtering: adds point_skip & point_offs
  546.           clift subdirectory:
  547.           From: ssclift@neumann.uwaterloo.ca (Simon Clift)
  548.           Subject: Re: Running gnuplot from Fortran, (and C)
  549.           green subdirectory:
  550.           From: Roque Donizete de Oliveira
  551.           Subject: PostScript Greek symbols in gnuplot, new prologue
  552.           hanna subdirectory:
  553.           From: gregor@kafka.saic.com (gregg hanna)
  554.           Subject: x11-library mode, gnulib_x11.[c,h],
  555.           xlibtest.c,makefile.xlib
  556.           klosowski subdirectory:
  557.           From: Carsten Steger
  558.           Subject: New file "klein.dat"
  559.           From: przemek@rrdstrad.nist.gov (Przemek Klosowski)
  560.           Subject: calling gnuplot from Fortran
  561.           kocaturk subdirectory:
  562.           From: mustafa@seas.smu.edu (Mustafa Kocaturk)
  563.           Subject: Histograms in gnuplot
  564.           richardson subdirectory:
  565.           From: amr@chiton.ucsd.edu (Tony Richardson)
  566.           Subject: Programmatic control of gnuplot from Unix
  567.           rosendorf subdirectory:
  568.           From: prf@jprix.che.wisc.edu
  569.           Subject: Multiple plots on a page
  570.           vanzandt subdirectory:
  571.           From: James R. Van Zandt
  572.           Subject: Spline generating program
  573.           white subdirectory:
  574.           From: gwhite@bionet.bio.dfo.ca
  575.           Subject: gnuplot 3.2 for Titan 3000
  576.           woo subdirectory:
  577.           From: "Alex Woo"
  578.           Subject: two additional title lines and fixes to errorbar style
  579.           
  580.           yamamoto subdirectory:
  581.           From: "NOBORU YAMAMOTO "
  582.           Subject: Re: gnuplot on Apple Macintosh, "diff -c" of version
  583.           3.0
  584.           (now includes binaries)
  585.           castro subdirectory:
  586.           From: maurice@bruce.cs.monash.edu.au (Maurice Castro)
  587.           Subject: Controlling gnuplot from another Windows program
  588.           grammes subdirectory:
  589.           From: ph12hucg@rz.uni-sb.de (Carsten Grammes)
  590.           Subject: Nonlinear least squares fit mechanism
  591.           henke subdirectory:
  592.           From: mgr@asgard.bo.open.de (Lars Hanke)
  593.           Subject: Re: Changes to gnuplot 3.3b9
  594.           walton subdirectory:
  595.           From: dwalton@athena.mit.edu (Dave Walton)
  596.           Subject: Inter Process Communication stuff
  597.           
  598.    Q5.4: Can I do heavy - duty data processing with gnuplot?
  599.           Gnuplot alone is not suited very well for this. One thing you
  600.           might try is fudgit, an interactive multi-purpose fitting
  601.           program written by Martin-D. Lacasse
  602.           (isaac@frodo.physics.mcgill.ca). It can use gnuplot as its
  603.           graphics back end and is available from ftp.physics.mcgill.ca
  604.           in /pub/Fudgit/fudgit_2.33.tar.Z [132.206.9.13], and from the
  605.           main Linux server, tsx-11.mit.edu [18.172.1.2] and its numerous
  606.           mirrors around the world as
  607.           /pub/linux/sources/usr.bin/fudgit-2.33.tar.z. Versions are
  608.           available for AIX, Data General, HP-UX, IRIX 4, Linux, NeXT,
  609.           Sun3, Sun4, Ultrix, OS/2 and MS-DOS. The MS-DOS version is
  610.           available on simtel20 mirrors (simtel20 itself has closed down)
  611.           in the "math" subdirectory as fudg_231.zip.
  612.           
  613.           Carsten Grammes has written a fitting program which goes
  614.           together with gnuplot; it is called gnufit and is available
  615.           from the official gnuplot sites, as the files gnufit12.info,
  616.           gnufit12.tar.gz (source) and gft12dos.zip (MS-DOS).
  617.           
  618.           Michael Courtney has written a program called lsqrft, which
  619.           uses the Levenberg - Marquardt - Algorithm for fitting data to
  620.           a function. It is avialiable from ftp.cdrom.com as
  621.           /pub/os2/2_x/unix/lsqrft13.zip; sources, which should compile
  622.           on Unix, and executables for MS-DOS and OS/2 2.x are included.
  623.           There is an interface to the OS/2 presentation manager.
  624.           
  625.           You might also want to look at the applications developed by
  626.           the Software Tools Group (STG) at the National Center for
  627.           Supercomputing Applications. Ftp to ftp.ncsa.uiuc.edu
  628.           [141.142.20.50] and get the file README.BROCHURE for more
  629.           information.
  630.           
  631.    Q5.5: I have ported gnuplot to another system, or patched it. What do
  632.           I do?
  633.           If your patch is small, mail it to bug-gnuplot@dartmouth.edu,
  634.           with a thorough description of what the patch is supposed to
  635.           do, which version of gnuplot it is relative to, etc. Please
  636.           don't mail it to the FAQ maintainer.
  637.           
  638.           If your modifications are extensive (such as a port to another
  639.           system), upload your modifications to
  640.           ftp.dartmouth.edu:/pub/dropoff. Please drop a note to
  641.           David.Kotz@dartmouth.edu, the maintainer of the gnuplot
  642.           subdirectory there, plus a note to bug-gnuplot@dartmouth.edu.
  643.           
  644.    
  645.      _________________________________________________________________
  646.    
  647.   SECTION 6: MAKING LIFE EASIER
  648.   
  649.     Q6.1: How do I plot two functions in non - overlapping regions?
  650.           Use a parametric plot. An example:
  651.           
  652.  
  653.         set parametric
  654.         a=1
  655.         b=3
  656.         c=2
  657.         d=4
  658.         x1(t) = a+(b-a)*t
  659.         x2(t) = c+(d-c)*t
  660.         f1(x) = sin(x)
  661.         f2(x) = x**2/8
  662.         plot [t=0:1] x1(t),f1(x1(t)) title "f1", x2(t), f2(x2(t)) title "f2"
  663.  
  664.    Q6.2: How do I run my data through a filter before plotting?
  665.           If your system supports the popen() - function, as Unix does,
  666.           you should be able to run the output through another process
  667.           such as a short awk program (use the "help plot datafile"
  668.           command for an example). Unfortunately, in 3.2, there is a
  669.           rather short limitation on the maximum argument length, so your
  670.           command line may be truncated (usually, this will mean that awk
  671.           cannot find the filename). Also, you may need to escape the $ -
  672.           characters in your awk programs.
  673.           
  674.           As of version 3.4, gnuplot includes the thru - keyword for the
  675.           plot command for running data files through a gnuplot - defined
  676.           function.
  677.           
  678.           You can also get divhack.trm from
  679.           sotona.phys.soton.ac.uk[152.78.192.42] via anonymous ftp. It
  680.           allows expressions of the kind
  681.           
  682.  
  683.         gnuplot> plot "datafile" using A:B:C
  684.  
  685.    where A,B,C,... are now either a column number, as usual, or an
  686.           arbitrary expression enclosed in ()'s, and using $1,$2,etc to
  687.           access the data columns.
  688.           
  689.    Q6.3: How do I make it easier to use gnuplot with LaTeX?
  690.           There is a set of LaTeX macros and shell scripts that are meant
  691.           to make your life easier when using gnuplot with LaTeX. This
  692.           package can be found on ftp.dartmouth.edu [129.170.16.54] in
  693.           pub/gnuplot/latex.shar, by David Kotz. For example, the program
  694.           "plotskel" can turn a gnuplot-output file plot.tex into a
  695.           skeleton file skel.tex, that has the same size as the original
  696.           plot but contains no graph. With the right macros, the skeleton
  697.           can be used for preliminary LaTeX passes, reserving the full
  698.           graph for later passes, saving tremendous amounts of time.
  699.           
  700.    Q6.4: How do I save and restore my settings?
  701.           Use the "save" and "load" commands for this; see "help save"
  702.           and "help load" for details.
  703.           
  704.    Q6.5: How do I plot lines (not grids) using splot?
  705.           If the data in a data file for splot is arranged in such a way
  706.           that each one has the same number of data points (using blank
  707.           lines as delimiters, as usual), splot will plot the data with a
  708.           grid. If you want to plot just lines, use a different number of
  709.           data entries (you can do this by doubling the last data point,
  710.           for example). Don't forget to set parametric mode, of course.
  711.           
  712.    Q6.6: How do I plot a function f(x,y) which is bounded by other
  713.           functions in the x-y plain?
  714.           An example:
  715.           
  716.  
  717.         f(x,y) = x**2 + y **2
  718.         x(u) = 3*u
  719.         yu(x) = x**2
  720.         yl(x) = -x**2
  721.         set parametric
  722.         set cont
  723.         splot [0:1] [0:1] u,yl(x(u))+(yu(x(u)) - yl(x(u)))*v,\
  724.         f(x(u), (yu(x(u)) - yl(x(u)))*v)
  725.  
  726.    Q6.7: How do I get rid of <feature in a plot>?
  727.           Usually, there is a set command to do this; do a
  728.           
  729.  
  730.         gnuplot> ?set no
  731.  
  732.    for a short overview.
  733.           
  734.    Q6.8: How do I call gnuplot from my own programs?
  735.           Here's code which works for a UNIX system, using (efficient)
  736.           named pipes.
  737.           
  738.  
  739. #include <sys/types.h>
  740. #include <sys/stat.h>
  741. #include <stdlib.h>
  742. #include <stdio.h>
  743. #include <math.h>
  744. #include <unistd.h>
  745.  
  746. #define PANIC(a) do { \
  747.                 perror(a); \
  748.                 if (temp_name) unlink(temp_name);\
  749.                 exit(1);\
  750.         } while(0)
  751.  
  752. int main() {
  753.     FILE *command,*data;
  754.     char *temp_name;
  755.     double a,b;
  756.     int i;
  757.  
  758.     if ((temp_name = tmpnam((char *) 0)) == 0) PANIC("tmpnam failed");
  759.     if(mkfifo(temp_name, S_IRUSR | S_IWUSR) != 0) PANIC("mkfifo failed");
  760.     command = popen("gnuplot","w");
  761.     fprintf(command,"plot \"%s\" with lines\n",temp_name); fflush(command);
  762.     data = fopen(temp_name,"w");
  763.     for (i=0; i<20; i++) {
  764.         a = i/10.0;
  765.         b = sin(a);
  766.         fprintf(data,"%f %f\n",a,b);
  767.     }
  768.     fclose(data);
  769.     fprintf(stderr,"press enter to continue..."); fflush(stderr);
  770.     getchar();
  771.  
  772.     fprintf(command,"plot \"%s\" with lines\n",temp_name); fflush(command);
  773.     data = fopen(temp_name,"w");
  774.     for (i=0; i<20; i++) {
  775.         a = i/10.0;
  776.         b = cos(a);
  777.         fprintf(data,"%f %f\n",a,b);
  778.     }
  779.     fclose(data);
  780.     fprintf(stderr,"press enter to continue..."); fflush(stderr);
  781.     getchar();
  782.     fclose(command);
  783.     unlink(temp_name);
  784.     return 0;
  785. }
  786.  
  787.    Here's code for OS/2, again using named pipes; I'm unable to check
  788.           this out myself. This code is care of fearick@physci.uct.ac.za
  789.           (Roger Fearick).
  790.           
  791.  
  792. #include <stdio.h>
  793. #define INCL_DOS
  794. #define INCL_DOSPROCESS
  795. #define INCL_DOSNMPIPES
  796. #include <os2.h>
  797.  
  798. main()
  799.     {
  800.     HPIPE hpipe ;
  801.     FILE *hfile, *hgnu ;
  802.         /* create a named pipe. Use NP_WAIT so that DosConnect...
  803.            blocks until client (gnuplot) opens, and client reads
  804.            are blocked until data is available */
  805.     DosCreateNPipe( "\\pipe\\gtemp",
  806.                     &hpipe,
  807.                     NP_ACCESS_OUTBOUND,
  808.                     NP_WAIT|NP_TYPE_BYTE|1,
  809.                     256,
  810.                     256,
  811.                     -1 ) ;
  812.         /* use stream i/o */
  813.     hfile = fdopen( hpipe, "w" ) ;
  814.  
  815.         /* start gnuplot; use unbuffered writes so we don't need to
  816.            flush buffer after a command */
  817.     hgnu = popen( "gnuplot", "w" ) ;
  818.     setvbuf( hgnu, NULL, _IONBF, 0 ) ;
  819.  
  820.         /* plot a set of data */
  821.  
  822.     fprintf( hgnu, "plot '/pipe/gtemp'\n" ) ;  /* issue plot command */
  823.     DosConnectNPipe( hpipe ) ;              /* wait until 'file' opened */
  824.     fprintf( hfile, "1 1\n" ) ;             /* write data to 'file' */
  825.     fprintf( hfile, "2 2\n" ) ;
  826.     fprintf( hfile, "3 3\n" ) ;
  827.     fprintf( hfile, "4 4\n" ) ;
  828.     fflush( hfile ) ;                       /* flush buffer forces read */
  829.     DosSleep( 500 ) ;                       /* allow gnuplot to catch up */
  830.     DosDisConnectNPipe( hpipe ) ;           /* disconnect this session */
  831.     fprintf( hgnu, "pause -1\n" ) ;         /* admire plot */
  832.  
  833.         /* plot another set of data */
  834.  
  835.     fprintf( hgnu, "plot '/pipe/gtemp'\n" ) ;
  836.     DosConnectNPipe( hpipe ) ;
  837.     fprintf( hfile, "1 4\n" ) ;
  838.     fprintf( hfile, "2 3\n" ) ;
  839.     fprintf( hfile, "3 2\n" ) ;
  840.     fprintf( hfile, "4 1\n" ) ;
  841.     fflush( hfile ) ;
  842.     DosSleep( 500 ) ;
  843.     DosDisConnectNPipe( hpipe ) ;
  844.     fprintf( hgnu, "pause -1\n" ) ;
  845.  
  846.     DosClose( hpipe ) ;
  847.     pclose( hgnu ) ;
  848.     }
  849.  
  850.    ;
  851.           
  852.    
  853.      _________________________________________________________________
  854.    
  855.   SECTION 7: KNOWN PROBLEMS
  856.   
  857.     Q7.1: Gnuplot is not plotting any points under X11! How come?
  858.           Very probably, you still are using an old version of
  859.           gnuplot_x11. Remove that, then do a full installation.
  860.           
  861.           On VMS, you need to make several symbols:
  862.           
  863.  
  864.         $ gnuplot_x11 :== $disk:[directory]gnuplot_x11
  865.         $ gnuplot :== $disk:[directory]gnuplot.exe
  866.         $ def/job GNUPLOT$HELP disk:[directory]gnuplot.hlb
  867.  
  868.    Then run gnuplot from your command line, and use
  869.           
  870.  
  871.         gnuplot> set term x11
  872.  
  873.    Q7.2: My isoline data generated by a Fortran program is not handled
  874.           correctly. What can I do?
  875.           One known cause for this is the use of list - directed output
  876.           (as in WRITE(10,*) for generating blank lines. Fortran uses ASA
  877.           carriage control characters, and for list - directed output
  878.           this results in a space being output before the newline.
  879.           Gnuplot does not like this. The solution is to generate blank
  880.           lines using formatted output, as in WRITE(10,'()'). If you use
  881.           carriage return files in VMS Fortran, you may have to open the
  882.           file with OPEN(...,CARRIAGECONTROL='DTST') or convert it using
  883.           the DECUS utility ATTRIB.EXE:
  884.           
  885.  
  886.         VMS> ATTRIB/RATTRIB=IMPDTED FOR010.DAT
  887.  
  888.    Q7.3: Why does gnuplot ignore my very small numbers?
  889.           Gnuplot treats all numbers less than 1e-08 as zero, by default.
  890.           Thus, if you are trying to plot a collection of very small
  891.           numbers, they may be plotted as zero. Worse, if you're plotting
  892.           on a log scale, they will be off scale. Or, if the whole set of
  893.           numbers is "zero", your range may be considered empty:
  894.           
  895.  
  896.         gnuplot> plot 'test1'
  897.         Warning: empty y range [4.047e-19:3e-11], adjusting to [-1:1]
  898.         gnuplot> set yrange [4e-19:3e-11]
  899.         gnuplot> plot 'test1'
  900.                      ^
  901.          y range is less than `zero`
  902.  
  903.    The solution is to change gnuplot's idea of "zero":
  904.           
  905.  
  906.         gnuplot> set zero 1e-20
  907.  
  908.    For more information,
  909.           
  910.  
  911.         gnuplot> help set zero
  912.  
  913.    Q7.4: Gnuplot is plotting nothing when run via gnuplot <filename>!
  914.           What can I do?
  915.           Put a pause -1 after the plot command in the file.
  916.           
  917.    Q7.5: My formulas are giving me nonsense results! What's going on?
  918.           Gnuplot does integer, and not floating point, arithmetic on
  919.           integer expressions. For example, the expression 1/3 evaluates
  920.           to zero. If you want floating point expressions, supply
  921.           trailing dots for your floating point numbers. Example:
  922.           
  923.  
  924.         gnuplot> print 1/3
  925.                 0
  926.         gnuplot> print 1./3.
  927.                 0.333333
  928.  
  929.    This way of evaluating integer expressions is shared by both C and
  930.           Fortran.
  931.           
  932.    
  933.      _________________________________________________________________
  934.    
  935.    Section 8: Credits
  936.    
  937.   SECTION 8: CREDITS
  938.   
  939.    This list was initially compiled by John Fletcher with contributions
  940.    from Russell Lang, John Campbell, David Kotz, Rob Cunningham, Daniel
  941.    Lewart and Alex Woo. Reworked by Thomas Koenig from a draft by Alex
  942.    Woo, with corrections and additions from Alex Woo, John Campbell,
  943.    Russell Lang, David Kotz and many corrections from Daniel Lewart; Axel
  944.    Eble and Jutta Zimmermann helped with the conversion to HTML.
  945.    
  946.    
  947.      _________________________________________________________________
  948.    
  949.     Thomas Koenig, ig25@rz.uni-karlsruhe.de, 1994-03-28
  950. -- 
  951. Thomas Koenig, ig25@rz.uni-karlsruhe.de, ig25@dkauni2.bitnet,
  952. The joy of engineering is to find a straight line on a double
  953. logarithmic diagram.
  954.  
  955.